package cn.alibab.cangku.controller;


import cn.alibab.cangku.service.AreaService;
import cn.alibab.common.model.R;
import org.springframework.web.bind.annotation.*;

@RestController
@RequestMapping("area")
@CrossOrigin
public class AreaController {
    public final AreaService areaService;

    public AreaController(AreaService areaService) {
        this.areaService = areaService;
    }
    @GetMapping("findByArea/{abc}")
    public R findByArea(@PathVariable("abc") String abc) {
        System.out.println(abc);
        return areaService.findByArea(abc);
    }
}
